package com.learn.xueer.ui.activity

import android.os.Bundle
import com.learn.xueer.app.base.BaseActivity
import com.learn.xueer.databinding.ActivityMyClassBinding
import com.learn.xueer.ui.viewmodel.MineViewModel
import kotlinx.android.synthetic.main.activity_my_class.tv_grade
import kotlinx.android.synthetic.main.activity_my_class.tv_school
import me.hgj.jetpackmvvm.util.get
import me.hgj.jetpackmvvm.util.startActivity

/**
 * 我的班级
 */
class MyClassActivity : BaseActivity<MineViewModel, ActivityMyClassBinding>() {


    inner class ProxyClick {
        fun back() {
            finish()
        }

        fun change() {
            startActivity(ChangeClassActivity::class)
        }


    }

    override fun initView(savedInstanceState: Bundle?) {
        mDatabind.click = ProxyClick()
        mDatabind.viewmodel = mViewModel
        var schoolName = intent.get<String>("schoolName").toString()
        var grade = intent.get<String>("grade").toString()
        tv_grade.text = grade
        tv_school.text = schoolName

//        CacheDataManager.clearAllCache(this@ClearCacheActivity)
//        ToastUtils.showShort("清除缓存成功")
    }
}